package com.kcwl.carrier.infrastructure.repository.persostence;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.kcwl.carrier.domain.entity.VehiclePlateCityRef;
import com.kcwl.carrier.domain.repository.IGroupMappingRepository;
import com.kcwl.carrier.domain.repository.IVehiclePlateCityRefRepository;
import com.kcwl.carrier.infrastructure.repository.mapper.GroupMappingMapper;
import com.kcwl.carrier.infrastructure.repository.mapper.VehiclePlateCityRefMapper;
import com.kcwl.carrier.infrastructure.repository.po.GroupMappingPO;
import com.kcwl.carrier.infrastructure.repository.po.VehiclePlateCityRefPO;
import com.kcwl.ddd.domain.repository.BaseRepositoryImpl;
import com.kcwl.framework.utils.KcBeanConverter;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @author 刘旭超
 * @date 2022年07月11日 16:33
 * @Description
 */
@Service
public class VehiclePlateCityRefRepositoryImpl extends BaseRepositoryImpl<VehiclePlateCityRefMapper, VehiclePlateCityRefPO> implements IVehiclePlateCityRefRepository {

    @Resource
    private VehiclePlateCityRefMapper vehiclePlateCityRefMapper;


    @Override
    public VehiclePlateCityRefPO queryByPlateNo(String plateNumber) {
        QueryWrapper<VehiclePlateCityRefPO> wrapper = new QueryWrapper<>();
        wrapper.eq("plate_no", plateNumber);
        return vehiclePlateCityRefMapper.selectOne(wrapper);
    }
}
